<?php
/* 
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 * Description of autoload
 *
 * @author Nhan Nguyen
 */
defined('IN_ADMIN') or die('Hacking Attempt!');

$_sClassDir = array(
        'include' => INCLUDE_DIR,
        'module' => MODULE_DIR,
        'module' => MODULE_ADMIN_DIR
    );

//auto load class files
function __autoload($sClassName){
    global $_sClassDir;
    foreach($_sClassDir as $sDirectory){
        if(file_exists($sDirectory.$sClassName.CLASS_EXT))
            require_once $sDirectory.$sClassName.CLASS_EXT;
    }
}
?>
